package com.company.springhibernate.hibernatedaosupport.service;

import java.util.Collection;
import java.util.List;

import com.company.modelo.Student;
import com.company.springhibernate.hibernatedaosupport.dao.StudentDao;


public class HibernateStudentService implements StudentService {
	
	StudentDao studentdao;
	
	public void setStudentdao(StudentDao studentdao) {
		this.studentdao = studentdao;
	}

	public Student getStudent(Integer id) {		
		return this.studentdao.getStudent(id);
	}

	public List<Student> getAllStudents() {
		return this.studentdao.getAllStudents();
	}

	public List<Student> getGraduatedStudents() {
		return this.studentdao.getGraduatedStudents();
	}

	public List<Student> findStudents(String lastName) {
		return this.studentdao.findStudents(lastName);
	}

	public void saveStudent(Student std) {
		this.studentdao.saveStudent(std);		
	}

	public void removeStudent(Student std) {
		this.studentdao.removeStudent(std);		
	}

	

}
